Skip to content

Conversation

@bootjp
Copy link
Owner

@bootjp bootjp commented Aug 29, 2025

Summary

  • run Jepsen suite unconditionally in CI by setting RUN_JEPSEN to true

Testing

  • go test ./...
  • RUN_JEPSEN=true ~/lein test

https://chatgpt.com/codex/tasks/task_e_68b087e80e74832498e0c726ca1beef5

Comment on lines +9 to +26
runs-on: ubuntu-latest
env:
RUN_JEPSEN: 'true'
steps:
- uses: actions/checkout@v5
- uses: actions/setup-java@v4
with:
distribution: temurin
java-version: '21'
- name: Install Leiningen
run: |
curl -L https://raw.githubusercontent.com/technomancy/leiningen/stable/bin/lein > ~/lein
chmod +x ~/lein
~/lein version
- name: Run Jepsen tests
if: env.RUN_JEPSEN == 'true'
working-directory: jepsen
run: ~/lein test

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}

Copilot Autofix

AI 5 months ago

To fix the issue, add a permissions block specifying the minimum required permissions for the workflow. The best practice is to set contents: read at either the workflow root or per-job basis. For this workflow, since the job does not require write permissions (no deployment, repository pushing, etc.), we can safely set contents: read at the workflow root. This will limit the GITHUB_TOKEN permissions for all jobs that do not declare their own overrides. Edit .github/workflows/jepsen-test.yml by inserting the following after the name: block and before jobs: on line 7:

permissions:
  contents: read

This ensures the workflow runs with the principle of least privilege.

Suggested changeset 1
.github/workflows/jepsen-test.yml

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/.github/workflows/jepsen-test.yml b/.github/workflows/jepsen-test.yml
--- a/.github/workflows/jepsen-test.yml
+++ b/.github/workflows/jepsen-test.yml
@@ -4,6 +4,8 @@
   group: ${{ github.workflow }}-${{ github.ref }}-jepsen-test
 
 name: Jepsen Test
+permissions:
+  contents: read
 jobs:
   test:
     runs-on: ubuntu-latest
EOF
@@ -4,6 +4,8 @@
group: ${{ github.workflow }}-${{ github.ref }}-jepsen-test

name: Jepsen Test
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
Copilot is powered by AI and may make mistakes. Always verify output.
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codex Review: Here are some suggestions.

https://github.com/bootjp/elastickv/blob/e7c0ac78eb9b1420dde6328752ca570792c4868e/jepsen/src/elastickv/jepsen_test.clj#L39-L38
[P1] Use valid Redis port in Jepsen client

The Jepsen test constructs its Redis client with ->RedisClient 63791, which means open! will instantiate Jedis on port 63791. Port numbers must be in the 0–65535 range, so this throws java.lang.IllegalArgumentException: port out of range before the test ever runs. As a result the workflow always crashes when the Jepsen suite is executed. This should use a valid port (e.g., 6379) or a configurable value.


Reply with @codex fix comments to fix any unresolved comments.

About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you open a pull request for review, mark a draft as ready, or comment "@codex review". If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex fix this CI failure" or "@codex address that feedback".

@bootjp bootjp enabled auto-merge August 29, 2025 17:48
@bootjp bootjp merged commit cdc2c08 into main Aug 29, 2025
7 checks passed
@bootjp bootjp deleted the codex/implement-jepsen-test-2lucqi branch August 29, 2025 17:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants